layoutInit= function() {
    var ps = tb_getPageSize();
                
    var hd_h = 50;
    var ft_h = 25;
    var lf_w = 190;
                
    var tmp1 = 0;
    var tmp2 = 0;
    if($.browser.msie) {
        tmp1 = 6;
        tmp2 = 6*3;
    } else {
        tmp1 = 6 + 3;
        tmp2 = 6*3 + 4;
    }
    var ct_h = ps[1] - hd_h - ft_h;
    //var ct_w = ps[0] - lf_w - tmp2;
    var ct_w = ps[0];
                
    $("#header").css("height", hd_h + "px");
    $("#footer").css("height", ft_h + "px");
    //$("#left").css("width", lf_w + "px");
    //$("#left").css("height", ct_h + "px");
    $("#content").css("width", ct_w + "px");
    $("#content").css("height", ct_h + "px");

    // 设置 Form 的大小
    // sysFormEditor 为全局变量，在 editor 页面上定义
    var formInfo = document.getElementById("FormInfo");
    var form_info_h = formInfo.innerHeight || formInfo.clientHeight;
    sysFormEditor.setRect(ct_w, ct_h - form_info_h);
    sysFormEditor.setForm();
        
    // 窗口大小变化时重新设置布局
    if($.browser.msie) {
        $("#box").resize(layoutInit);
    } else {
        window.onresize = layoutInit;
    }
}

pageInit = function() {              
    // thickbox 初始化
    tb_init('a.thickbox, area.thickbox, input.thickbox');
}
